
import 'dart:convert';

import 'package:flutter/foundation.dart';

main(){
  var runner = Runner("SunJH");
  runner.result = (){
    print("调用了外部传入函数");
  };
  runner.response = (name){
    print(name);
  };
  runner.run();

}
class Runner{
  VoidCallback? result;
  Function(String)? response;
  String name;
  Runner(this.name);
  void run(){
    result?.call();
    response?.call(name);
  }
}